#include <iostream>
using namespace std;
bool judge(string s) {
    int l = s.length();
    for(int i = 0; i < l; ++i) {
        if(!((s[i] - '0') % 2)) continue;
        else return false;
    }
    return true;
}
int main() {
    int t;
    cin >> t;
    string s;
    for(int i = 0; i < t; ++i) {
        cin >> s;
        if(judge(s)){
            cout << "Yes" << endl;
        }else {
            cout << "No" << endl;
        }
    }
}

